<mat-form-field class="example-user-input">
  <input matInput placeholder="Show delay (milliseconds)"
         type="number"
         aria-label="Adds a delay between hovering over the button and displaying the tooltip"
         [formControl]="showDelay">
</mat-form-field>

<mat-form-field class="example-user-input">
  <input matInput placeholder="Hide delay (milliseconds)"
         type="number"
         aria-label="Adds a delay between hovering away from the button and hiding the tooltip"
         [formControl]="hideDelay">
</mat-form-field>

<button mat-raised-button
        matTooltip="Info about the action"
        [matTooltipShowDelay]="showDelay.value"
        [matTooltipHideDelay]="hideDelay.value"
        aria-label="Button that displays a tooltip with a customized delay in showing and hiding">
  Action
</button>
